﻿<%@ Control Language="c#" AutoEventWireup="false" Inherits="Web.Control.WWW.Contacts.InviteConfirm" %>
<div style="width: 500px; text-align: center">
    <div style="padding: 10px; text-align: left; margin: 0 auto; width: 450px">
        <div id="Panel1"  style="display: none">
            <div id="Content">
                <h3><%=GetText("CT047", new string[] { HttpUtility.HtmlEncode(FNickName) })%></h3>
                <p>
                    <strong><%=GetText("CT048")%></strong><br />
                    <textarea id="txtContent"  rows="6" name="txtUserName" class="common300"></textarea>
                </p>                
                <p style="text-align: center;">
                    <input type="button" id="Send" value="<%=GetText("C0047")%>" class="button" onclick="AddFSendM()" />
                    <input type="button" value="<%=GetText("C0056")%>" class="button" onclick="parent.window.neatDialog.close();" />
                </p>                
            </div>
        </div>
        <div id="AddPanel" style="display: none">            
            <h3><%=GetText("CT051", new string[] { HttpUtility.HtmlEncode(FNickName) })%></h3><br />
            <p style="text-align: center;">
                <input type="button" value="<%=GetText("C0069")%>" id="addOkButton" class="button" onclick="AddNewFriend(0)" />
                <input type="button" value="<%=GetText("C0056")%>" onclick="parent.window.neatDialog.close();" class="button" />
            </p>
        </div>
        <div id="Panel2" style="display: none">
            <h3><%=GetText("CT041", new string[] { HttpUtility.HtmlEncode(FNickName) })%></h3>
            <br />
            <p style="text-align: center;">
                <input type="button" value="<%=GetText("C0064")%>" class="buttong" onclick="parent.window.neatDialog.close();" />
            </p>
        </div>
        <div id="Panel3" style="display: none">
            <h3><%=GetText("CT049", new string[] { HttpUtility.HtmlEncode(FNickName) })%></h3><br />
            <p style="text-align: center;">
                <input type="button" value="<%=GetText("C0064")%>" class="buttong" onclick="parent.window.neatDialog.close();" />
            </p>
        </div>
        <div id="Panel4" style="display: none">
            <h3><%=GetText("CT050",new string[]{FNickName})%></h3><br />
            <p style="text-align: center;">
                <input type="button" value="<%=GetText("C0064")%>" class="buttong" onclick="parent.window.neatDialog.close();" />
            </p>
        </div>
        <div id="Succeed" style="display: none">
            <h3><%=GetText("C1002")%></h3>
            <p style="text-align: center;">
                <input type="button" value="<%=GetText("C0064")%>" class="buttong" onclick="parent.window.location.reload();" />
            </p>
        </div>
        <div id="failure" style="display: none">
            <h3><%=GetText("C1006")%></h3>
            <p style="text-align: center;">
                <input type="button" value="<%=GetText("C0064")%>" class="buttong" onclick="parent.window.neatDialog.close();" />
            </p>
        </div>
    </div>
</div>
<span id="valMessage" style="color: Red; display: none;" class="red10"></span>

<script>
var MyMemberno = "<%=memberno %>";
var FMemberno = "<%=FMemberno %>";
var FNickName = "<%=FNickName%>";
var MyNickName = "<%=MyNickName %>";
var FEmail = "<%=FEmail %>";
var IsFriend = <%=IsFriend %>;
var IsLink = <%=IsLink %>;
var IsAgreeFriend = <%=IsAgreeFriend %>;
var EmailOption = <%=EmailOption %>;

var Page_Validators =  new Array($get("valMessage"));
var TmpObj = $get("valMessage");
TmpObj.controltovalidate = "txtContent";
TmpObj.errormessage = "<b><%=GetText("C1010")%></b><br /><%=GetText("ST155",new string[]{"3","2000"})%>";
TmpObj.display = "None";
TmpObj.evaluationfunction = "RegularExpressionValidatorEvaluateIsValid";
TmpObj.validationexpression = "[\\s\\S]{3,2000}";
var Page_ValidationActive = false;
if (typeof(ValidatorOnLoad) == "function") {
    ValidatorOnLoad();
}
function ValidatorOnSubmit() {
    if (Page_ValidationActive) {
        return ValidatorCommonOnSubmit();
    }
    else {
        return true;
    }
}
function CreateValid()
{
     $create(AjaxControlToolkit.ValidatorCalloutBehavior, 
    {"closeImageUrl":"<%=RootPath%>Scripts/AjaxTools/images/close.gif","highlightCssClass":"validatorCalloutHighlight",
    "id":"valMessage","warningIconImageUrl":"<%=RootPath%>Scripts/AjaxTools/images/alert-small.gif"}, null, null, $get("valMessage"));
}
</script>

